package com.soft.mainsite.module.category.service;

import java.util.List;

import com.soft.mainsite.mybatis.model.TCmsCategory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import com.soft.mainsite.module.category.dao.TCmsCategoryDao;

/**
 * TCmsCategoryService.java 此类用于网站栏目接口
 *
 * @author:刘兴家
 * @date:2019/4/15 
 * @remark:
 */
@Component
public class TCmsCategoryServiceImpl implements TCmsCategoryService{
	
	 @Autowired
	 private TCmsCategoryDao categoryDao;
	   /**
		  * 查询站点栏目
		* @param pid父栏目id,siteId站点Id
		* @return
		*/
	@Override
	public List<TCmsCategory> findCategoryListByPid(Long pid, Integer siteId) {
		
		return categoryDao.findCategoryListByPid(pid, siteId);
	}
	
	/**
     * 根据站点id、父标签id、是否导航条件查询栏目
    * @param 
    * @return 
	 */
	@Override
	public List<TCmsCategory> findCategoryListByPidAndIsNav(Long pid, Integer siteId, Integer isNav) {		
		return categoryDao.findCategoryListByPidAndIsNav(pid, siteId, isNav);
	}

}
